package game.leon.war.game;

import game.leon.engine.net.GameServer;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

import java.io.IOException;

/**
 * User: bianpeng
 * Date: 12-1-11
 * 面向用户
 */
@Component
public class WarGame {
    @Value("#{app.game_port}")
    private int port;
    @Value("#{app.name}")
    private String name;
    @Autowired
    private GameReciever gameReciever;
    private GameServer gameServer = new GameServer();
    public void start() throws IOException {
        gameServer.start(port, gameReciever);
    }
}
